<body>
<{$xajax_scripts}> 
<div class='form_title'><{$smarty.const.MI_ANALYZE_RESULT}> - <{$smarty.const.MI_OLD_SAMPLES_SEARCH_RESULT}></div>
<table align=center cellspacing='0' cellpadding='0' border='0'><tr><td align=center>
<table align=center class='analysis_content' cellspacing='1' cellpadding='1' border='0'>
<tr>
<td colspan=5>
<table border=0 class='analysis_header'>
<tr>
<td colspan=<{$serology_match_info|@count}>><{$smarty.const.MI_POSITIVE_WELL}>: <font color=red><{$display_primer_numbers}></font></td>
</tr>
<tr>
<{foreach from=$serology_match_info key=serology_id item=info}>
<td><b><font color=red><{$info.match_count}></font> <{$serology_id}> <{$smarty.const.MI_LOCUS}></b></td>
<{/foreach}>
</tr>
<tr id='imperfect_counts' style='display:none;'>
<{foreach from=$serology_match_info key=serology_id item=info}>
<td style='border: 1px dotted #ccccff;'><b><font color=red><{$info.imperfect_count}></font> <{$serology_id}> <{$smarty.const.MI_IMPERFECT_WELL}></b></td>
<{/foreach}>
</tr>
<tr id='rare_counts' style='display: none'>
<{foreach from=$serology_match_info key=serology_id item=info}>
<td style='border: 1px dotted #ccccff;'><b><font color=red><{$info.rare_count}></font> <{$serology_id}> <{$smarty.const.MI_RARE_ITEMS}></b></td>
<{/foreach}>
</tr>
</table>
</td>
</tr>
<tr>
<td>&nbsp;</td>
<th><{$smarty.const.MI_SEROTYPE_1}></th>
<th><{$smarty.const.MI_SEROTYPE_2}></th>
<th><{$smarty.const.MI_GENOTYPES}></th>
</tr>
<{foreach from=$matchs item=match}>
<{  foreach from=$match item=line}>
<tr style='display: none;'><td>
<input type='hidden' name='line<{$line.pno}>_serology_id' value='<{$line.serology_id}>'>
<input type='hidden' name='line<{$line.pno}>_line_no1' value='<{$line.line_no1}>'>
<input type='hidden' name='line<{$line.pno}>_line_no2' value='<{$line.line_no2}>'>
<input type='hidden' name='line<{$line.pno}>_primer_numbers' value='<{$line.match_save_primer_numbers}>'>
<input type='hidden' name='line<{$line.pno}>_frequency' value='<{$line.frequency}>'>
<input type='hidden' name='line<{$line.pno}>_imperfect' value='<{$line.imperfect}>'>
<input type='hidden' name='line<{$line.pno}>_rare' value='<{$line.rare}>'>
</td></tr>
<td style='padding-top: 4px; text-align: left;'><b><{$line.match_numbers}></b></td>
<td><input type='text' class='imperfect_field' readonly style='background-color:<{$line.view_color}>;' size=14 name='line<{$line.pno}>_serotype1' value='<{$line.serotype1}>'></td>
<td><input type='text' class='imperfect_field' readonly style='background-color:<{$line.view_color}>;' size=14 name='line<{$line.pno}>_serotype2' value='<{$line.serotype2}>'></td>
<td><textarea class='imperfect_field' readonly style='background-color:<{$line.view_color}>;' cols=70 rows=1 name='line<{$line.pno}>_genotypes' onfocus='this.rows=3;' onblur='this.rows=1;'><{$line.genotypes}></textarea></td>
</tr>
<{  /foreach}>
<{/foreach}>
<td colspan=4 style='text-align:right;'><b><{$smarty.const.MI_IS_FINAL}></b>
<input type='hidden' name='save_primer_numbers' value='<{$save_primer_numbers}>'></td>
</table>
<table class='form_detail' cellspacing='1' cellpadding='1' border='0'>
<tr>
  <th><{$smarty.const.MI_SAMPLE_ID}></th>
  <td><{$sample_id}><input type='hidden' name='sample_id' value=''></td>
  <th><{$smarty.const.MI_SELECT_KIT_ID}></th>
  <td><{$kit_id}></td>
</tr>
<tr>
  <th><{$smarty.const.MI_DNA_EXT_METHOD}></th>
  <td><{$dna_ext_method}>&nbsp;</td>
  <th><{$smarty.const.MI_DNA_OD}></th>
  <td><{$dna_od}>&nbsp;</td>
</tr>
<tr>
  <th><{$smarty.const.MI_KIT_LOT_NO}></th>
  <td colspan=3><{foreach from=$lot_list item=line}>
      <{if $lot_no==$line.lot_no}><{$line.lot_no}> / <{$smarty.const.MI_KIT_LOT_EXPIRES}> <{$line.lot_expires}><{/if}>
<{/foreach}>&nbsp;</td>
</tr>
<tr>
  <th><{$smarty.const.MI_TEST_BY}></th>
  <td><{$test_by}>&nbsp;</td>
  <th><{$smarty.const.MI_TEST_DATE}></th>
  <td><{$test_date}>&nbsp;</td>
</tr>
<tr>
  <th><{$smarty.const.MI_COMMENT}></th>
  <td colspan=3><{$comment}>&nbsp;</td>
</tr>
<tr>
  <th><{$smarty.const.MI_INSTITUTION}></th>
  <td colspan=3><{$institution}>&nbsp;</td>
</tr>
<tr>
  <th><{$smarty.const.MI_ETHNIC}></th>
  <td colspan=3><{$ethnic}>&nbsp;</td>
</tr>
<tr>
  <th><{$smarty.const.MI_FIRST_NAME}></th>
  <td><{$first_name}>&nbsp;</td>
  <th><{$smarty.const.MI_LAST_NAME}></th>
  <td><{$last_name}>&nbsp;</td>
</tr>
<tr>
  <th><{$smarty.const.MI_SEX}></th>
  <td><{if $sex=='M'}><{$smarty.const._MALE}><{/if}><{if $sex=='F'}><{$smarty.const._FEMALE}><{/if}>&nbsp;</td>
  <th><{$smarty.const.MI_AGE}></th>
  <td><{$age}>&nbsp;</td>
</tr>
<tr>
  <td colspan=4 style='text-align:center;border:0;'>
    <input type='button' class='button' value="&nbsp;<{$smarty.const.MI_PRINT}>&nbsp;" onclick='location.href="/sample_output_old.php?sample_id=<{$sample_id}>";'>
<{if !empty($search_uri)}>
    <input type='button' class='button' value="&nbsp;<{$smarty.const.MI_BACK_SEARCH}>&nbsp;" onclick='location.href="<{$search_uri}>"'>
<{else}>
    <input type='button' class='button' value="&nbsp;<{$smarty.const.MI_BACK}>&nbsp;" onclick='history.go(-1);'>
<{/if}>
<{if !empty($prior_sample_id)}>
    <input type='button' class='button' value="&nbsp;<{$smarty.const.MI_PRIOR_SAMPLE}>&nbsp;" onclick='location.href="/search.php?op=old_detail&sample_id=<{$prior_sample_id}>";'>
<{/if}>
<{if !empty($next_sample_id)}>
    <input type='button' class='button' value="&nbsp;<{$smarty.const.MI_NEXT_SAMPLE}>&nbsp;" onclick='location.href="/search.php?op=old_detail&sample_id=<{$next_sample_id}>";'>
<{/if}>
    </td>
</tr>
</table>
</td></tr></table>
